class Player(object):
    def __init__(self, name, age):
        self.name = name
        self.age = age


    @staticmethod
    def isvaild(**kwargs):
        if kwargs['age'] > 18:
            return True
        else:
            return False

data = {'name': 'tom', 'age': 11}
if Player.isvaild(**data):
    tom = Player('tom', 11)
else:
    print('try again!')

